package com.lzh.shijicloudstack.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.lzh.shijicloudstack.model.entity.Ingredient;
import org.apache.ibatis.annotations.MapKey;

import java.util.List;
import java.util.Map;


/**
 * 食材表数据库访问层
 *
 * @author luzhiheng
 * @since 2024-12-28 16:14:28
 */
public interface IngredientMapper extends BaseMapper<Ingredient> {

    /**
     * 根据查询条件统计总数
     *
     * @param queryMap 查询条件
     * @return Integer
     */
    Integer countList(Map<String, Object> queryMap);

    /**
     * 分页查询
     *
     * @param queryMap 查询条件
     * @return List<Map < String, Object>>
     */
    @MapKey(value = "id")
    List<Map<String, Object>> pageList(Map<String, Object> queryMap);
}

